<template>
    <view>
        <view class="container">
            <view class="orderlist" v-for="(item, index) in list" :key="index">
                <view class="content">
                    <view class="jobinfo">
                        <view class="jobleft">
                            <view>10</view>
                            <view>投递简历</view>
                        </view>
                        <view class="line"></view>

                        <view class="jobright">
                            <view class="jobtitle">
                                <view>{{ item.jobtitle }}</view>
                                <view @tap="editCompanyjob" :data-id="item.id"><image src="/static/imgs/icon/edit.png" /></view>
                            </view>
                            <view>人数:{{ item.num }} | 薪资:{{ item.money }}</view>

                            <view>到期:{{ item.endtime }} | 置顶:{{ item.toptime }}</view>
                            <view>
                                创建:{{ item.createtime }}
                                <text style="color: red">({{ item.status == 0 ? '审核通过' : '待审核' }})</text>
                            </view>
                        </view>
                    </view>

                    <view class="payitem">
                        <view v-if @tap="topPaytopjob" :data-id="item.id">置顶</view>

                        <view v-if @tap="toMatchnote" :data-id="item.worktype">匹配</view>

                        <view v-if @tap="toSharejob" :data-id="item.id">分享</view>

                        <view v-if @tap="doCompanyendtime" :data-id="item.id">同步</view>

                        <block v-if="item.status == 0">
                            <view v-if @tap="cancleJob" :data-id="item.id">下架</view>
                        </block>
                        <block v-else>
                            <view v-if @tap="upJob" :data-id="item.id">上架</view>
                        </block>
                    </view>
                </view>
            </view>
        </view>

        <view class="weixinmao-float">
            <view class="weixinmao-foot">
                <view class="footer" @tap="addcompanyjob">添加任务</view>
            </view>
        </view>
    </view>
</template>

<script>
// pages/mytaskjob/index.js
export default {
    data() {
        return {
            list: []
        };
    }
    /**
     * 生命周期函数--监听页面加载
     */,
    onLoad: function (options) {},
    /**
     * 生命周期函数--监听页面初次渲染完成
     */
    onReady: function () {},
    /**
     * 生命周期函数--监听页面显示
     */
    onShow: function () {},
    /**
     * 生命周期函数--监听页面隐藏
     */
    onHide: function () {},
    /**
     * 生命周期函数--监听页面卸载
     */
    onUnload: function () {},
    /**
     * 页面相关事件处理函数--监听用户下拉动作
     */
    onPullDownRefresh: function () {},
    /**
     * 页面上拉触底事件的处理函数
     */
    onReachBottom: function () {},
    /**
     * 用户点击右上角分享
     */
    onShareAppMessage: function () {},
    methods: {
        editCompanyjob() {
            console.log('占位：函数 editCompanyjob 未声明');
        },

        topPaytopjob() {
            console.log('占位：函数 topPaytopjob 未声明');
        },

        toMatchnote() {
            console.log('占位：函数 toMatchnote 未声明');
        },

        toSharejob() {
            console.log('占位：函数 toSharejob 未声明');
        },

        doCompanyendtime() {
            console.log('占位：函数 doCompanyendtime 未声明');
        },

        cancleJob() {
            console.log('占位：函数 cancleJob 未声明');
        },

        upJob() {
            console.log('占位：函数 upJob 未声明');
        },

        addcompanyjob() {
            console.log('占位：函数 addcompanyjob 未声明');
        }
    }
};
</script>
<style>
/* pages/companyjob/index.wxss */

.container {
    background-color: #f5f5f5;
    min-height: 100%;
}
.container .orderlist {
    width: 100%;
    display: flex;
    flex-direction: column;
    background: #fff;
    margin-top: 10rpx;
}
.container .orderlist .orderid {
    border-bottom: 1rpx solid #efefef;
    padding-top: 20rpx;
    padding-bottom: 20rpx;
    padding-left: 20rpx;
    font-size: 0.8rem;
    width: 720rpx;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
}
.container .orderlist .orderid image {
    width: 50rpx;
    height: 50rpx;
}

.container .orderlist .content {
    font-size: 0.8rem;
    border-bottom: 1rpx solid #efefef;
}
.container .orderlist .content .item {
    padding-top: 16rpx;
    padding-bottom: 16rpx;
    padding-left: 20rpx;
    border-bottom: 1rpx dotted #efefef;
    display: flex;
    flex-direction: row;
}
.syscompany {
    width: 180rpx;
    height: 60rpx;
    line-height: 60rpx;
    text-align: center;
    margin-right: 20rpx;
    border-radius: 5rpx;
    background: #44b549;
    font-size: 0.6rem;
    color: #fff;
    margin-left: 230rpx;
}
.container .orderlist .content .payitem {
    width: 720rpx;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    padding-bottom: 20rpx;
    padding-top: 20rpx;
    margin-left: 20rpx;
}
.container .orderlist .content .payitem view {
    width: 120rpx;
    height: 60rpx;
    line-height: 60rpx;
    text-align: center;
    margin-right: 20rpx;
    border-radius: 5rpx;
    border: 1rpx solid #f5f5f5;
    font-size: 0.6rem;
    color: #666666;
}
/*
.container .orderlist .content .payitem view:nth-child(1){

  background: #44b549;

}
.container .orderlist .content .payitem view:nth-child(2){

  background: #3274e5;

}

.container .orderlist .content .payitem view:nth-child(3){

  background: #e64340;

}

*/

.weixinmao-float {
    height: 150rpx;
}
.weixinmao-foot {
    display: flex;
    justify-content: center;
    flex-direction: row;
    position: fixed;
    z-index: 999;
    left: 0;
    bottom: 0;
    width: 100%;
}

.weixinmao-foot view {
    color: #fff;
    height: 100rpx;
    line-height: 100rpx;
    font-size: 0.9rem;
    width: 100%;
    border-radius: 0rpx;
    background: #e64340;
    text-align: center;
}

.intro {
    padding: 10rpx;
    font-size: 0.8rem;
}

.jobinfo {
    width: 100%;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    border-bottom: 1rpx solid #f5f5f5;
}
.jobinfo .jobleft {
    width: 200rpx;
    height: 200rpx;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
.jobinfo .jobleft view:nth-child(1) {
    font-weight: 600;
    font-size: 1.5rem;
}

.jobinfo .jobleft view:nth-child(2) {
    color: #666666;
    font-size: 0.7rem;
}

.jobinfo .jobleft {
    width: 230rpx;
    height: 230rpx;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.jobinfo .jobright {
    width: 500rpx;
    height: 230rpx;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.jobinfo .jobright .jobtitle {
    font-weight: 600;
    font-size: 1.2rem;
    display: flex;
    flex-direction: row;
}
.jobinfo .jobright .jobtitle image {
    width: 45rpx;
    height: 45rpx;
    margin-left: 30rpx;
}

.jobinfo .jobright view:nth-child(2) {
    color: #666666;
    font-size: 0.7rem;
}

.jobinfo .jobright view:nth-child(3) {
    color: #666666;
    font-size: 0.7rem;
}

.jobinfo .jobright view:nth-child(4) {
    color: #666666;
    font-size: 0.7rem;
}
.line {
    height: 230rpx;
    border: 1rpx dotted #f5f5f5;
}
</style>
